package com.cyj.minio.common;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;
import javax.persistence.MappedSuperclass;

/**
 * @Description: 基类
 * @BelongsProject: SpringBoot-MinIO
 * @BelongsPackage: com.cyj.minio.common
 * @Author: ChenYongJia
 * @CreateTime: 2021-09-13 14:53
 * @Email: chen87647213@163.com
 * @Version: 1.0
 */
@Data
@MappedSuperclass
public class BaseEntity implements Serializable {

    @JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    @JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "修改时间")
    private Date updateTime;

    @ApiModelProperty(value = "是否删除（0--未删除 1--已删除）")
    private Integer delFlag;

}
